package com.qfedu.schedule;

import com.qfedu.service.UserService;
import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.springframework.beans.factory.annotation.Autowired;

/**
 * @author LiJH
 * @date 2023-02-01
 */
public class MyJob implements Job{
    @Autowired
    private UserService userService;
    @Override
    public void execute(JobExecutionContext context) throws JobExecutionException {
        //执行业务
//        System.out.println("execute method   "+LocalDateTime.now());
        userService.addUser();
    }
}